/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package myheartsgame;

import java.awt.*;
import java.util.ArrayList;
import javax.swing.*;

/**
 *
 * @author KaKa
 */
public class MainPanel extends JPanel {

    ArrayList<Image> _bgImageManager;
    public int _iCurrentImage;    

    public MainPanel() {
        _iCurrentImage = 0;
        _bgImageManager = new ArrayList<Image>();

        String bgImage = "/Pictures/Theme/CardTable.png";
        ImageIcon picture = new ImageIcon(getClass().getResource(bgImage));

        _bgImageManager.add(picture.getImage());        
    }

    @Override
    protected void paintComponent(Graphics g) {
        super.paintComponent(g);

        g.drawImage(_bgImageManager.get(_iCurrentImage), 0, 0, null);        
    }
}
